package DataStorageClasses;

import java.sql.Date;

import org.json.JSONException;
import org.json.JSONObject;

public class Employee 
{
	private long empID;
	private String firstName;
	private String lastName;
	private String busName;
	private Date start;
	private Date finished;
	private double wage;
	private long SIN;
	private String streetAd;
	private String city;
	private String province;
	private String postalCode;
	private String homeTel;
	private String cell;
	
	public Employee(long id, String first, String last, String bus, Date start, Date finish, double wage, long SIN, String street, String city, String prov,
						String postal, String home, String cell)
	{
		this.empID = id;
		this.firstName = first;
		this.lastName = last;
		this.busName = bus;
		this.start = start;
		this.finished = finish;
		this.wage = wage;
		this.SIN = SIN;
		this.streetAd = street;
		this.city = city;
		this.province = prov;
		this.city = city;
		this.postalCode = postal;
		this.homeTel = home;
		this.cell = cell;
	}
	
	public long getEmployeeID()
	{
		return empID;
	}
	
	public String getFirstName()
	{
		return firstName;
	}
	
	public String getLastName()
	{
		return lastName;
	}
	
	public String getBusinessName()
	{
		return busName;
	}
	
	public Date getDateHired()
	{
		return start;
	}
	
	public Date getDateFired()
	{
		return finished;
	}
	
	public double getWage()
	{
		return wage;
	}
	
	public long getSIN()
	{
		return SIN;
	}
	
	public String getCity()
	{
		return city;
	}
	
	public String getProvince()
	{
		return province;
	}
	
	public String getPostalCode()
	{
		return postalCode;
	}
	
	public String getHomeTel()
	{
		return homeTel;
	}
	
	public String getCell()
	{
		return cell;
	}
	
	public String getStreet()
	{
		return streetAd;
	}
	
	public JSONObject getJSONObject() throws JSONException
	{
		JSONObject json = new JSONObject();
		
		json.put("empID", empID);
		json.put("firstName", firstName);
		json.put("lastName", lastName);
		json.put("start", start);
		json.put("finished", finished);
		json.put("wage", wage);
		json.put("SIN", SIN);
		json.put("streetAd", streetAd);
		json.put("city", city);
		json.put("province", province);
		json.put("postalCode", postalCode);
		json.put("homeTel", homeTel);
		json.put("cell", cell);
		
		return json;
	}
}
